Error Text:
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '}' at line 1 ....
Query Text:
select p.*, t.fname as type, c.fname as category from san_products p left join san_cat c on (c.code=p.cat_code) left join san_type t on (t.code=p.type_code) where p.code={code}
Sandy McCormack